<?php
/*
 *  @author Nicolas Genevaux
 * (c)nige 2008
 */
	for($i=0;$_SESSION['questions'][$i];$i++) {
		$courbeEvolution[$i] = $_SESSION['questions'][$i]['reussi']/($_SESSION['questions'][$i]['compteur']+1)*5;
		$resultats[$_SESSION['questions'][$i]['matiere']] += $_SESSION['questions'][$i]['reussi']/($_SESSION['questions'][$i]['compteur']);
		$total[$_SESSION['questions'][$i]['matiere']]++;
	}
	$_SESSION['courbeEvolution'] = $courbeEvolution;
	$keyResult = array_keys($total);
	$affichageResultats = '<br /><br />';
	for($i=0;$keyResult[$i];$i++) {
		$affichageResultats .= '- <b>'.$keyResult[$i].' : </b> '.round($resultats[$keyResult[$i]]/$total[$keyResult[$i]]*100).'% <br />';
	}
?>
